home *** CD-ROM | disk | FTP | other *** search
/ CU Amiga Super CD-ROM 14 / CU Amiga Magazine's Super CD-ROM 14 (1997)(EMAP Images)(GB)(Track 1 of 3)[!][issue 1997-09].iso / CUCD / Programming / Mesa-2.2 / src / teximage.h < prev    next >
Encoding:
C/C++ Source or Header  |  1997-03-13  |  6.9 KB  |  194 lines

  1. /* $Id: teximage.h,v 1.3 1997/02/09 18:53:05 brianp Exp $ */
  2.  
  3. /*
  4.  * Mesa 3-D graphics library
  5.  * Version:  2.2
  6.  * Copyright (C) 1995-1997  Brian Paul
  7.  *
  8.  * This library is free software; you can redistribute it and/or
  9.  * modify it under the terms of the GNU Library General Public
  10.  * License as published by the Free Software Foundation; either
  11.  * version 2 of the License, or (at your option) any later version.
  12.  *
  13.  * This library is distributed in the hope that it will be useful,
  14.  * but WITHOUT ANY WARRANTY; without even the implied warranty of
  15.  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
  16.  * Library General Public License for more details.
  17.  *
  18.  * You should have received a copy of the GNU Library General Public
  19.  * License along with this library; if not, write to the Free
  20.  * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
  21.  */
  22.  
  23.  
  24. /*
  25.  * $Log: teximage.h,v $
  26.  * Revision 1.3  1997/02/09 18:53:05  brianp
  27.  * added GL_EXT_texture3D support
  28.  *
  29.  * Revision 1.2  1996/11/07 04:13:24  brianp
  30.  * all new texture image handling, now pixel scale, bias, mapping work
  31.  *
  32.  * Revision 1.1  1996/09/13 01:38:16  brianp
  33.  * Initial revision
  34.  *
  35.  */
  36.  
  37.  
  38. #ifndef TEXIMAGE_H
  39. #define TEXIMAGE_H
  40.  
  41.  
  42. #include "types.h"
  43.  
  44.  
  45. /*** Internal functions ***/
  46.  
  47.  
  48. extern struct gl_texture_image *gl_alloc_texture_image( void );
  49.  
  50.  
  51. extern void gl_free_texture_image( struct gl_texture_image *teximage );
  52.  
  53.  
  54. extern struct gl_image *
  55. gl_unpack_texsubimage( GLcontext *ctx, GLint width, GLint height,
  56.                        GLenum format, GLenum type, const GLvoid *pixels );
  57.  
  58.  
  59. extern struct gl_image *
  60. gl_unpack_texsubimage3D( GLcontext *ctx, GLint width, GLint height,GLint depth,
  61.                          GLenum format, GLenum type, const GLvoid *pixels );
  62.  
  63.  
  64. extern struct gl_texture_image *
  65. gl_unpack_texture( GLcontext *ctx,
  66.                    GLint dimensions,
  67.                    GLenum target,
  68.                    GLint level,
  69.                    GLint internalformat,
  70.                    GLsizei width, GLsizei height,
  71.                    GLint border,
  72.                    GLenum format, GLenum type,
  73.                    const GLvoid *pixels );
  74.  
  75. extern struct gl_texture_image *
  76. gl_unpack_texture3D( GLcontext *ctx,
  77.                      GLint dimensions,
  78.                      GLenum target,
  79.                      GLint level,
  80.                      GLint internalformat,
  81.                      GLsizei width, GLsizei height, GLsizei depth,
  82.                      GLint border,
  83.                      GLenum format, GLenum type,
  84.                      const GLvoid *pixels );
  85.  
  86.  
  87. extern void gl_tex_image_1D( GLcontext *ctx,
  88.                              GLenum target, GLint level, GLint internalformat,
  89.                              GLsizei width, GLint border, GLenum format,
  90.                              GLenum type, const GLvoid *pixels );
  91.  
  92.  
  93. extern void gl_tex_image_2D( GLcontext *ctx,
  94.                              GLenum target, GLint level, GLint internalformat,
  95.                              GLsizei width, GLint height, GLint border,
  96.                              GLenum format, GLenum type,
  97.                              const GLvoid *pixels );
  98.  
  99. extern void gl_tex_image_3D( GLcontext *ctx,
  100.                              GLenum target, GLint level, GLint internalformat,
  101.                              GLsizei width, GLint height, GLint depth,
  102.                              GLint border,
  103.                              GLenum format, GLenum type,
  104.                              const GLvoid *pixels );
  105.  
  106.  
  107. /*** API entry points ***/
  108.  
  109.  
  110. extern void gl_TexImage1D( GLcontext *ctx,
  111.                            GLenum target, GLint level, GLint internalformat,
  112.                            GLsizei width, GLint border, GLenum format,
  113.                            GLenum type, struct gl_image *teximage );
  114.  
  115.  
  116. extern void gl_TexImage2D( GLcontext *ctx,
  117.                            GLenum target, GLint level, GLint internalformat,
  118.                            GLsizei width, GLsizei height, GLint border,
  119.                            GLenum format, GLenum type,
  120.                            struct gl_image *teximage );
  121.  
  122.  
  123. extern void gl_TexImage3DEXT( GLcontext *ctx,
  124.                               GLenum target, GLint level, GLint internalformat,
  125.                               GLsizei width, GLsizei height, GLsizei depth,
  126.                               GLint border,
  127.                               GLenum format, GLenum type,
  128.                               struct gl_image *teximage );
  129.  
  130.  
  131. extern void gl_GetTexImage( GLcontext *ctx, GLenum target, GLint level,
  132.                             GLenum format, GLenum type, GLvoid *pixels );
  133.  
  134.  
  135.  
  136. extern void gl_TexSubImage1D( GLcontext *ctx,
  137.                               GLenum target, GLint level, GLint xoffset,
  138.                               GLsizei width, GLenum format, GLenum type,
  139.                               struct gl_image *image );
  140.  
  141.  
  142. extern void gl_TexSubImage2D( GLcontext *ctx,
  143.                               GLenum target, GLint level,
  144.                               GLint xoffset, GLint yoffset,
  145.                               GLsizei width, GLsizei height,
  146.                               GLenum format, GLenum type,
  147.                               struct gl_image *image );
  148.  
  149.  
  150. extern void gl_TexSubImage3DEXT( GLcontext *ctx,
  151.                                  GLenum target, GLint level,
  152.                                  GLint xoffset, GLint yoffset, GLint zoffset,
  153.                                  GLsizei width, GLsizei height, GLsizei depth,
  154.                                  GLenum format, GLenum type,
  155.                                  struct gl_image *image );
  156.  
  157.  
  158. extern void gl_CopyTexImage1D( GLcontext *ctx,
  159.                                GLenum target, GLint level,
  160.                                GLenum internalformat,
  161.                                GLint x, GLint y,
  162.                                GLsizei width, GLint border );
  163.  
  164.  
  165. extern void gl_CopyTexImage2D( GLcontext *ctx,
  166.                                GLenum target, GLint level,
  167.                                GLenum internalformat, GLint x, GLint y,
  168.                                GLsizei width, GLsizei height,
  169.                                GLint border );
  170.  
  171.  
  172. extern void gl_CopyTexSubImage1D( GLcontext *ctx,
  173.                                   GLenum target, GLint level,
  174.                                   GLint xoffset, GLint x, GLint y,
  175.                                   GLsizei width );
  176.  
  177.  
  178. extern void gl_CopyTexSubImage2D( GLcontext *ctx,
  179.                                   GLenum target, GLint level,
  180.                                   GLint xoffset, GLint yoffset,
  181.                                   GLint x, GLint y,
  182.                                   GLsizei width, GLsizei height );
  183.  
  184.  
  185. extern void gl_CopyTexSubImage3DEXT( GLcontext *ctx,
  186.                                      GLenum target, GLint level,
  187.                                      GLint xoffset, GLint yoffset,
  188.                                      GLint zoffset,
  189.                                      GLint x, GLint y,
  190.                                      GLsizei width, GLsizei height );
  191.  
  192. #endif
  193.  
  194.